//
//  YLStatusRetweetView.swift
//  weiBo
//
//  Created by 杨雷 on 2016/12/7.
//  Copyright © 2016年 Yang.L. All rights reserved.
//

import UIKit

class YLStatusRetweetView: UIView {

    var statusViewModel : YLStatusViewModel? {
        didSet{
            contentLabel.text = statusViewModel?.status?.retweeted_status?.text
        }
    }
    
    
    
    //懒加载
    private lazy var contentLabel: UILabel = {
        let label = UILabel(font: 14, textColor: UIColor.gray)
        
        label.numberOfLines = 0
        
        label.text = "阿斯顿法国和加快了去维尔体育自学成才"
        
        return label
        
        
    }()
    
    
    
    
    override init(frame: CGRect) {
        super.init(frame: frame)
        setupUI()
    }
    
    required init?(coder aDecoder: NSCoder) {
        fatalError("init(coder:) has not been implemented")
    }

    private func setupUI () {
        addSubview(contentLabel)
        
        contentLabel.snp.makeConstraints { (make) in
            make.top.equalTo(self).offset(StatusItemMargin)
            
            make.left.equalTo(self).offset(StatusItemMargin)
            
            make.width.equalTo(screenWidth - 2 * StatusItemMargin)
        }
        
        self.snp.makeConstraints { (make) in
            make.bottom.equalTo(contentLabel).offset(StatusItemMargin)
        }
        
    }
    
    
    
    
    
    
}
